local hx__xicao = fk.CreateSkill {
  name = "hx__xicao",
  tags = { Skill.Compulsory},
}

hx__xicao:addEffect(fk.TargetSpecified, {
  anim_type = "offensive",
  can_trigger = function(self, event, target, player, data)
    local x = player.maxHp - player.hp
    local y = player.hp
    if x > y then
    return target == player and player:hasSkill(hx__xicao.name) and  data.card.trueName == "slash"
    elseif x < y then
      return target == player and player:hasSkill(hx__xicao.name) and  data.card.trueName == "duel"
    end
  end,
  on_use = function(self, event, target, player, data)
    local room = player.room
    data.additionalDamage = (data.additionalDamage or 0) + 1
    data.disresponsive = true
  end,
})

return hx__xicao